1. Field of the Invention
The present invention relates to a storage device that includes a nonvolatile semiconductor memory, a control device that controls the storage device, a storage system, and a storage method.
2. Description of the Related Art
A nonvolatile semiconductor memory, such as a NAND flash memory, includes an element that writes data to be stored after once deleting data in units called block when storing data, an element that reads/writes data in units called page; and an element from/into which a unit of deletion/reading/writing is fixed. The unit of reading and writing is predetermined for each semiconductor storage device, and is one of factors on which the life and characteristics of a storage device depend.
A NAND flash memory has a character such that deterioration of memory cells (memory elements) increases along with increase in the number of times of deletion of a block that is performed prior to writing of data.
On the other hand, a unit of reading/writing of data from/into a secondary storage device, such as a hard disk, performed by a host device, such as a personal computer, is called sector. The sector is determined independently from the unit of deletion/reading/writing from/into a semiconductor memory.
For example, it is determined such that the size of a block (block size) of a semiconductor memory is 512 kilobytes, and the size of a page (page size) is four kilobytes, while the size of a sector (sector size) of a host device is 512 bytes.
To improve reliability, a storage system used in a server environment, such as disk arrays, is often configured to be included in Redundant Arrays of Independent/Inexpensive Disks (RAID), for example, as described in D. Patterson, G. Gibsonand R. Katz. “A Case for Redundant Arrays of Inexpensive Disks (RAID)”, Proceedings of the 1988 ACM SIGMOD, pp. 109-116, June 1988. According to RAID, a RAID controller stores data in units called stripe into a plurality of disks. The size of a stripe (stripe size) is determined independently from a unit of reading/writing from/into a disk. Usually a magnetic storage device, such as a hard disk, is used in a storage system included in RAID; however, recently, cases of using a Solid State Drive (SSD) that uses a nonvolatile semiconductor memory as described above have increased. In such case, the stripe size is also determined independently from a unit of deletion/reading/writing from/into the nonvolatile semiconductor memory.
However, despite that there is an optimal unit of data-access against deterioration of a memory element in a storage device that uses a nonvolatile semiconductor memory as described above, such unit of access does not always agree with a unit of data-access of a host device, consequently there is a problem that memory elements cannot be efficiently used in some cases.